import {
    secklist,
} from '../../../request/app'

const state = {
    menulist: [],
}

const getters = {
    getlist(state) {
        return state.menulist
    },
}

const mutations = {
    SETlist(state, payload) {
        state.menulist = payload
    },
}

const actions = {
    ACgetlist(content) {
        secklist()
            .then(res => {
                content.commit('SETlist', res.list == null ? [] : res.list)
            })
    },
}

export default {
    state,
    mutations,
    actions,
    getters,
    namespaced: true
}